// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5
import QtQuick 1.1

Rectangle {
    id: parentRect
    width: 1280
    height: 720
    color: "#00000000"
    opacity:1
    signal openFullGallery()
    function takepic(ms){
        var t=setTimeout("snapScreen()",ms);
    }
    function snapScreen(){
        //parentRect.state="blank";
    }

    Image {
        id: image1
        x: 290
        y: 595
        width: 100
        height: 100
        smooth: true
        source: "Assets/camera/shutter.png"
    }

    Rectangle {
        id: giveSeconds
        x: 50
        y: 571
        width: 200
        height: 57
        color: "#ffffff"
        border.color:"black"
        border.width:3
        Text{
            anchors.horizontalCenter: parent.horizontalCenter
            anchors.verticalCenter: parent.verticalCenter
            text:"5 Seconds"
            font.pixelSize: 36
        }
        MouseArea{
            x:0;y:0;width:parent.width;height:parent.height
            onClicked: {snapScreen(50000);}
        }
    }

    Rectangle {
        id: tenSeconds
        x: 50
        y: 648
        width: 200
        height: 57
        color: "#ffffff"
        border.color:"black"
        border.width:3
        Text{
            anchors.horizontalCenter: parent.horizontalCenter
            anchors.verticalCenter: parent.verticalCenter
            text:"10 Seconds"
            font.pixelSize: 36
        }
        MouseArea{
            x:0;y:0;width:parent.width;height:parent.height
            onClicked: {}
        }
    }

    Image {
        id: image2
        x: 1153
        y: 595
        width: 100
        height: 100
        smooth: true
        source: "Assets/camera/gallery.png"
        MouseArea{
            onClicked:{console.log("gallery icon clicked");openFullGallery();}
        }
    }
    states: [
        State {
            name: "blank"
            PropertyChanges {
                target: parentRect
                opacity: 0
            }
        }
    ]
}
//Westin
